home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Development / Source / Chef 1.1 so Folder / Chef ƒ / MSG Shell ƒ / msg prefs.h < prev    next >
Encoding:
C/C++ Source or Header  |  1994-02-16  |  2.1 KB  |  79 lines  |  [TEXT/KAHL]

  1. /**********************************************************************\
  2.  
  3. File:        msg prefs.h
  4.  
  5. Purpose:    This is the header file for msg prefs.c
  6.  
  7.  
  8. Chef -=- convert text to Swedish chef talk
  9. Copyright ©1994, Mark Pilgrim
  10.  
  11. This program is free software; you can redistribute it and/or modify
  12. it under the terms of the GNU General Public License as published by
  13. the Free Software Foundation; either version 2 of the License, or
  14. (at your option) any later version.
  15.  
  16. This program is distributed in the hope that it will be useful,
  17. but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  19. GNU General Public License for more details.
  20.  
  21. You should have received a copy of the GNU General Public License
  22. along with this program in a file named "GNU General Public License".
  23. If not, write to the Free Software Foundation, 675 Mass Ave,
  24. Cambridge, MA 02139, USA.
  25.  
  26. \**********************************************************************/
  27.  
  28. #include "Folders.h"
  29.  
  30. #define        PREFS_FILE_NAME            "\pChef prefs"
  31. #define        PREFS_TYPE                'PREF'
  32. // CREATOR is #defined in "program globals.h"
  33. #define        PREFS_HEADER_VERSION    1
  34.  
  35. extern    Boolean        gCanSavePrefs;
  36. extern    Str255        gMyName;
  37. extern    Str255        gMyOrg;
  38.  
  39. typedef struct
  40. {
  41.     char            regname[40];
  42.     char            regorg[40];
  43.     unsigned char    showsave;
  44.     unsigned char    addsuffix;
  45.     unsigned char    showprogress;
  46.     unsigned char    useRTF;
  47.     long            fileID;
  48. } PrefStruct;
  49.  
  50. int PreferencesInit(void);
  51. void PrefsError(int err);
  52. int OpenPrefsFile(int *prefsFileID);
  53. int SetupNewPrefsFile(int prefsFileID);
  54. void ClosePrefsFile(int prefsFileID);
  55. int GetNextPrefs(int prefsFileID);
  56. int SavePrefs(int prefsFileID);
  57. int CheckVersion(int prefsFileID);
  58. int GetFileID(void);
  59. int CheckFileID(void);
  60. int Virgin(int prefsFileID);
  61. void DefaultPrefs(void);
  62. void CopyGlobalsToPrefs(void);
  63. void CopyPrefsToGlobals(void);
  64. void GetRegistration(void);
  65. void SaveThePrefs(void);
  66.  
  67. enum
  68. {
  69.     prefs_allsWell=0,
  70.     prefs_diskReadErr=-1,
  71.     prefs_diskWriteErr=-2,
  72.     prefs_cantOpenPrefsErr=-3,
  73.     prefs_cantCreatePrefsErr=-4,
  74.     prefs_noMorePrefsErr=-5,
  75.     prefs_versionNotSupportedErr=-6,
  76.     prefs_virginErr=-7,
  77.     prefs_IDNotMatchErr=-8
  78. };
  79.